<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">

<html lang="en">

<head>
  <meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
  <title>LCOV - mbi.info - test/impl/unit_test_suite.ipp</title>
  <link rel="stylesheet" type="text/css" href="../../gcov.css">
</head>

<body>

  <table width="100%" border=0 cellspacing=0 cellpadding=0>
    <tr><td class="title">LTP GCOV extension - code coverage report</td></tr>
    <tr><td class="ruler"><img src="../../glass.png" width=3 height=3 alt=""></td></tr>

    <tr>
      <td width="100%">
        <table cellpadding=1 border=0 width="100%">
        <tr>
          <td class="headerItem" width="20%">Current&nbsp;view:</td>
          <td class="headerValue" width="80%" colspan=4><a href="../../index.html">directory</a> - <a href="index.html">test/impl</a> - unit_test_suite.ipp</td>
        </tr>
        <tr>
          <td class="headerItem" width="20%">Test:</td>
          <td class="headerValue" width="80%" colspan=4>mbi.info</td>
        </tr>
        <tr>
          <td class="headerItem" width="20%">Date:</td>
          <td class="headerValue" width="20%">2010-01-23</td>
          <td width="20%"></td>
          <td class="headerItem" width="20%">Instrumented&nbsp;lines:</td>
          <td class="headerValue" width="20%">106</td>
        </tr>
        <tr>
          <td class="headerItem" width="20%">Code&nbsp;covered:</td>
          <td class="headerValue" width="20%">61.3 %</td>
          <td width="20%"></td>
          <td class="headerItem" width="20%">Executed&nbsp;lines:</td>
          <td class="headerValue" width="20%">65</td>
        </tr>
        </table>
      </td>
    </tr>
    <tr><td class="ruler"><img src="../../glass.png" width=3 height=3 alt=""></td></tr>
  </table>

  <table cellpadding=0 cellspacing=0 border=0>
    <tr>
      <td><br></td>
    </tr>
    <tr>
      <td><pre class="source">
<span class="lineNum">       1 </span>                : //  (C) Copyright Gennadiy Rozental 2005-2008.
<span class="lineNum">       2 </span>                : //  Distributed under the Boost Software License, Version 1.0.
<span class="lineNum">       3 </span>                : //  (See accompanying file LICENSE_1_0.txt or copy at
<span class="lineNum">       4 </span>                : //  http://www.boost.org/LICENSE_1_0.txt)
<span class="lineNum">       5 </span>                : 
<span class="lineNum">       6 </span>                : //  See http://www.boost.org/libs/test for the library home page.
<span class="lineNum">       7 </span>                : //
<span class="lineNum">       8 </span>                : //  File        : $RCSfile$
<span class="lineNum">       9 </span>                : //
<span class="lineNum">      10 </span>                : //  Version     : $Revision: 49312 $
<span class="lineNum">      11 </span>                : //
<span class="lineNum">      12 </span>                : //  Description : privide core implementation for Unit Test Framework.
<span class="lineNum">      13 </span>                : //  Extensions could be provided in separate files
<span class="lineNum">      14 </span>                : // ***************************************************************************
<span class="lineNum">      15 </span>                : 
<span class="lineNum">      16 </span>                : #ifndef BOOST_TEST_UNIT_TEST_SUITE_IPP_012205GER
<span class="lineNum">      17 </span>                : #define BOOST_TEST_UNIT_TEST_SUITE_IPP_012205GER
<span class="lineNum">      18 </span>                : 
<span class="lineNum">      19 </span>                : // Boost.Test
<span class="lineNum">      20 </span>                : #include &lt;boost/detail/workaround.hpp&gt;
<span class="lineNum">      21 </span>                : #include &lt;boost/test/unit_test_suite_impl.hpp&gt;
<span class="lineNum">      22 </span>                : #include &lt;boost/test/framework.hpp&gt;
<span class="lineNum">      23 </span>                : #include &lt;boost/test/utils/foreach.hpp&gt;
<span class="lineNum">      24 </span>                : #include &lt;boost/test/results_collector.hpp&gt;
<span class="lineNum">      25 </span>                : #include &lt;boost/test/detail/unit_test_parameters.hpp&gt;
<span class="lineNum">      26 </span>                : 
<span class="lineNum">      27 </span>                : // Boost
<span class="lineNum">      28 </span>                : #include &lt;boost/timer.hpp&gt;
<span class="lineNum">      29 </span>                : 
<span class="lineNum">      30 </span>                : // STL
<span class="lineNum">      31 </span>                : #include &lt;algorithm&gt;
<span class="lineNum">      32 </span>                : #include &lt;vector&gt;
<span class="lineNum">      33 </span>                : 
<span class="lineNum">      34 </span>                : #include &lt;boost/test/detail/suppress_warnings.hpp&gt;
<span class="lineNum">      35 </span>                : 
<span class="lineNum">      36 </span>                : #if BOOST_WORKAROUND(__BORLANDC__, &lt; 0x600) &amp;&amp; \
<span class="lineNum">      37 </span>                :     BOOST_WORKAROUND(_STLPORT_VERSION, &lt;= 0x450) \
<span class="lineNum">      38 </span>                :     /**/
<span class="lineNum">      39 </span>                :     using std::rand; // rand is in std and random_shuffle is in _STL
<span class="lineNum">      40 </span>                : #endif
<span class="lineNum">      41 </span>                : 
<span class="lineNum">      42 </span>                : //____________________________________________________________________________//
<span class="lineNum">      43 </span>                : 
<span class="lineNum">      44 </span>                : namespace boost {
<span class="lineNum">      45 </span>                : 
<span class="lineNum">      46 </span>                : namespace unit_test {
<span class="lineNum">      47 </span>                : 
<span class="lineNum">      48 </span>                : // ************************************************************************** //
<span class="lineNum">      49 </span>                : // **************                   test_unit                  ************** //
<span class="lineNum">      50 </span>                : // ************************************************************************** //
<span class="lineNum">      51 </span>                : 
<span class="lineNum">      52 </span><span class="lineCov">             11 : test_unit::test_unit( const_string name, test_unit_type t )</span>
<span class="lineNum">      53 </span>                : : p_type( t )
<span class="lineNum">      54 </span>                : , p_type_name( t == tut_case ? &quot;case&quot; : &quot;suite&quot; )
<span class="lineNum">      55 </span>                : , p_id( INV_TEST_UNIT_ID )
<span class="lineNum">      56 </span>                : , p_name( std::string( name.begin(), name.size() ) )
<span class="lineNum">      57 </span><span class="lineCov">             11 : , p_enabled( true )</span>
<span class="lineNum">      58 </span>                : {
<span class="lineNum">      59 </span><span class="lineCov">             11 : }</span>
<span class="lineNum">      60 </span>                : 
<span class="lineNum">      61 </span>                : //____________________________________________________________________________//
<span class="lineNum">      62 </span>                : 
<span class="lineNum">      63 </span><span class="lineCov">             11 : test_unit::~test_unit()</span>
<span class="lineNum">      64 </span>                : {
<span class="lineNum">      65 </span><span class="lineCov">             11 :     framework::deregister_test_unit( this );</span>
<span class="lineNum">      66 </span><span class="lineCov">             11 : }</span>
<span class="lineNum">      67 </span>                : 
<span class="lineNum">      68 </span>                : //____________________________________________________________________________//
<span class="lineNum">      69 </span>                : 
<span class="lineNum">      70 </span>                : void
<span class="lineNum">      71 </span><span class="lineNoCov">              0 : test_unit::depends_on( test_unit* tu )</span>
<span class="lineNum">      72 </span>                : {
<span class="lineNum">      73 </span><span class="lineNoCov">              0 :     m_dependencies.push_back( tu-&gt;p_id );</span>
<span class="lineNum">      74 </span><span class="lineNoCov">              0 : }</span>
<span class="lineNum">      75 </span>                : 
<span class="lineNum">      76 </span>                : //____________________________________________________________________________//
<span class="lineNum">      77 </span>                : 
<span class="lineNum">      78 </span>                : bool
<span class="lineNum">      79 </span><span class="lineCov">             11 : test_unit::check_dependencies() const</span>
<span class="lineNum">      80 </span>                : {
<span class="lineNum">      81 </span><span class="lineCov">             11 :     BOOST_TEST_FOREACH( test_unit_id, tu_id, m_dependencies ) {</span>
<span class="lineNum">      82 </span><span class="lineNoCov">              0 :         if( !unit_test::results_collector.results( tu_id ).passed() )</span>
<span class="lineNum">      83 </span><span class="lineNoCov">              0 :             return false;</span>
<span class="lineNum">      84 </span>                :     }
<span class="lineNum">      85 </span>                : 
<span class="lineNum">      86 </span><span class="lineCov">             11 :     return true;</span>
<span class="lineNum">      87 </span>                : }
<span class="lineNum">      88 </span>                : 
<span class="lineNum">      89 </span>                : //____________________________________________________________________________//
<span class="lineNum">      90 </span>                : 
<span class="lineNum">      91 </span>                : void
<span class="lineNum">      92 </span><span class="lineNoCov">              0 : test_unit::increase_exp_fail( unsigned num )</span>
<span class="lineNum">      93 </span>                : {
<span class="lineNum">      94 </span><span class="lineNoCov">              0 :     p_expected_failures.value += num;</span>
<span class="lineNum">      95 </span>                : 
<span class="lineNum">      96 </span><span class="lineNoCov">              0 :     if( p_parent_id != 0 )</span>
<span class="lineNum">      97 </span><span class="lineNoCov">              0 :         framework::get&lt;test_suite&gt;( p_parent_id ).increase_exp_fail( num );</span>
<span class="lineNum">      98 </span><span class="lineNoCov">              0 : }</span>
<span class="lineNum">      99 </span>                : 
<span class="lineNum">     100 </span>                : //____________________________________________________________________________//
<span class="lineNum">     101 </span>                : 
<span class="lineNum">     102 </span>                : // ************************************************************************** //
<span class="lineNum">     103 </span>                : // **************                   test_case                  ************** //
<span class="lineNum">     104 </span>                : // ************************************************************************** //
<span class="lineNum">     105 </span>                : 
<span class="lineNum">     106 </span><span class="lineCov">              7 : test_case::test_case( const_string name, callback0&lt;&gt; const&amp; test_func )</span>
<span class="lineNum">     107 </span>                : : test_unit( name, (test_unit_type)type )
<span class="lineNum">     108 </span><span class="lineCov">              7 : , m_test_func( test_func )</span>
<span class="lineNum">     109 </span>                : {
<span class="lineNum">     110 </span>                :      // !! weirdest MSVC BUG; try to remove this statement; looks like it eats first token of next statement   
<span class="lineNum">     111 </span>                : #if BOOST_WORKAROUND(BOOST_MSVC,&lt;1300)   
<span class="lineNum">     112 </span>                :      0;   
<span class="lineNum">     113 </span>                : #endif 
<span class="lineNum">     114 </span><span class="lineCov">              7 :     framework::register_test_unit( this );</span>
<span class="lineNum">     115 </span><span class="lineCov">              7 : }</span>
<span class="lineNum">     116 </span>                : 
<span class="lineNum">     117 </span>                : //____________________________________________________________________________//
<span class="lineNum">     118 </span>                : 
<span class="lineNum">     119 </span>                : // ************************************************************************** //
<span class="lineNum">     120 </span>                : // **************                  test_suite                  ************** //
<span class="lineNum">     121 </span>                : // ************************************************************************** //
<span class="lineNum">     122 </span>                : 
<span class="lineNum">     123 </span>                : //____________________________________________________________________________//
<span class="lineNum">     124 </span>                : 
<span class="lineNum">     125 </span><span class="lineCov">              4 : test_suite::test_suite( const_string name )</span>
<span class="lineNum">     126 </span><span class="lineCov">              4 : : test_unit( name, (test_unit_type)type )</span>
<span class="lineNum">     127 </span>                : {
<span class="lineNum">     128 </span><span class="lineCov">              4 :     framework::register_test_unit( this );</span>
<span class="lineNum">     129 </span><span class="lineCov">              4 : }</span>
<span class="lineNum">     130 </span>                : 
<span class="lineNum">     131 </span>                : //____________________________________________________________________________//
<span class="lineNum">     132 </span>                : 
<span class="lineNum">     133 </span>                : void
<span class="lineNum">     134 </span><span class="lineCov">              9 : test_suite::add( test_unit* tu, counter_t expected_failures, unsigned timeout )</span>
<span class="lineNum">     135 </span>                : {
<span class="lineNum">     136 </span><span class="lineCov">              9 :     if( timeout != 0 )</span>
<span class="lineNum">     137 </span><span class="lineNoCov">              0 :         tu-&gt;p_timeout.value = timeout;</span>
<span class="lineNum">     138 </span>                : 
<span class="lineNum">     139 </span><span class="lineCov">              9 :     m_members.push_back( tu-&gt;p_id );</span>
<span class="lineNum">     140 </span><span class="lineCov">              9 :     tu-&gt;p_parent_id.value = p_id;</span>
<span class="lineNum">     141 </span>                : 
<span class="lineNum">     142 </span><span class="lineCov">              9 :     if( tu-&gt;p_expected_failures )</span>
<span class="lineNum">     143 </span><span class="lineNoCov">              0 :         increase_exp_fail( tu-&gt;p_expected_failures );</span>
<span class="lineNum">     144 </span>                : 
<span class="lineNum">     145 </span><span class="lineCov">              9 :     if( expected_failures )</span>
<span class="lineNum">     146 </span><span class="lineNoCov">              0 :         tu-&gt;increase_exp_fail( expected_failures );</span>
<span class="lineNum">     147 </span><span class="lineCov">              9 : }</span>
<span class="lineNum">     148 </span>                : 
<span class="lineNum">     149 </span>                : //____________________________________________________________________________//
<span class="lineNum">     150 </span>                : 
<span class="lineNum">     151 </span>                : void
<span class="lineNum">     152 </span><span class="lineNoCov">              0 : test_suite::add( test_unit_generator const&amp; gen, unsigned timeout )</span>
<span class="lineNum">     153 </span>                : {
<span class="lineNum">     154 </span>                :     test_unit* tu;
<span class="lineNum">     155 </span><span class="lineNoCov">              0 :     while((tu = gen.next(), tu))</span>
<span class="lineNum">     156 </span><span class="lineNoCov">              0 :         add( tu, 0, timeout );</span>
<span class="lineNum">     157 </span><span class="lineNoCov">              0 : }</span>
<span class="lineNum">     158 </span>                : 
<span class="lineNum">     159 </span>                : //____________________________________________________________________________//
<span class="lineNum">     160 </span>                : 
<span class="lineNum">     161 </span>                : void
<span class="lineNum">     162 </span><span class="lineNoCov">              0 : test_suite::remove( test_unit_id id )</span>
<span class="lineNum">     163 </span>                : {
<span class="lineNum">     164 </span><span class="lineNoCov">              0 :     std::vector&lt;test_unit_id&gt;::iterator it = std::find( m_members.begin(), m_members.begin(), id );</span>
<span class="lineNum">     165 </span>                : 
<span class="lineNum">     166 </span><span class="lineNoCov">              0 :     if( it != m_members.end() )</span>
<span class="lineNum">     167 </span><span class="lineNoCov">              0 :         m_members.erase( it );</span>
<span class="lineNum">     168 </span><span class="lineNoCov">              0 : }</span>
<span class="lineNum">     169 </span>                : 
<span class="lineNum">     170 </span>                : //____________________________________________________________________________//
<span class="lineNum">     171 </span>                : 
<span class="lineNum">     172 </span>                : test_unit_id
<span class="lineNum">     173 </span><span class="lineCov">              2 : test_suite::get( const_string tu_name ) const</span>
<span class="lineNum">     174 </span>                : {
<span class="lineNum">     175 </span><span class="lineCov">              2 :     BOOST_TEST_FOREACH( test_unit_id, id, m_members ) {</span>
<span class="lineNum">     176 </span><span class="lineNoCov">              0 :         if( tu_name == framework::get( id, test_id_2_unit_type( id ) ).p_name.get() )</span>
<span class="lineNum">     177 </span><span class="lineNoCov">              0 :             return id;</span>
<span class="lineNum">     178 </span>                :     }
<span class="lineNum">     179 </span>                : 
<span class="lineNum">     180 </span><span class="lineCov">              2 :     return INV_TEST_UNIT_ID;</span>
<span class="lineNum">     181 </span>                : }
<span class="lineNum">     182 </span>                : 
<span class="lineNum">     183 </span>                : //____________________________________________________________________________//
<span class="lineNum">     184 </span>                : 
<span class="lineNum">     185 </span>                : // ************************************************************************** //
<span class="lineNum">     186 </span>                : // **************               traverse_test_tree             ************** //
<span class="lineNum">     187 </span>                : // ************************************************************************** //
<span class="lineNum">     188 </span>                : 
<span class="lineNum">     189 </span>                : void
<span class="lineNum">     190 </span><span class="lineCov">             21 : traverse_test_tree( test_case const&amp; tc, test_tree_visitor&amp; V )</span>
<span class="lineNum">     191 </span>                : {
<span class="lineNum">     192 </span><span class="lineCov">             21 :     if( tc.p_enabled )</span>
<span class="lineNum">     193 </span><span class="lineCov">             21 :     V.visit( tc );</span>
<span class="lineNum">     194 </span><span class="lineCov">             21 : }</span>
<span class="lineNum">     195 </span>                : 
<span class="lineNum">     196 </span>                : //____________________________________________________________________________//
<span class="lineNum">     197 </span>                : 
<span class="lineNum">     198 </span>                : void
<span class="lineNum">     199 </span><span class="lineCov">             14 : traverse_test_tree( test_suite const&amp; suite, test_tree_visitor&amp; V )</span>
<span class="lineNum">     200 </span>                : {
<span class="lineNum">     201 </span><span class="lineCov">             14 :     if( !suite.p_enabled || !V.test_suite_start( suite ) )</span>
<span class="lineNum">     202 </span><span class="lineCov">              2 :         return;</span>
<span class="lineNum">     203 </span>                : 
<span class="lineNum">     204 </span>                :     try {
<span class="lineNum">     205 </span><span class="lineCov">             12 :         if( runtime_config::random_seed() == 0 ) {</span>
<span class="lineNum">     206 </span><span class="lineCov">             39 :             BOOST_TEST_FOREACH( test_unit_id, id, suite.m_members )</span>
<span class="lineNum">     207 </span><span class="lineCov">             27 :                 traverse_test_tree( id, V );</span>
<span class="lineNum">     208 </span>                :         }
<span class="lineNum">     209 </span>                :         else {
<span class="lineNum">     210 </span><span class="lineNoCov">              0 :             std::vector&lt;test_unit_id&gt; members( suite.m_members );</span>
<span class="lineNum">     211 </span><span class="lineNoCov">              0 :             std::random_shuffle( members.begin(), members.end() );</span>
<span class="lineNum">     212 </span><span class="lineNoCov">              0 :             BOOST_TEST_FOREACH( test_unit_id, id, members )</span>
<span class="lineNum">     213 </span><span class="lineNoCov">              0 :                 traverse_test_tree( id, V );</span>
<span class="lineNum">     214 </span>                :         }
<span class="lineNum">     215 </span>                :         
<span class="lineNum">     216 </span><span class="lineNoCov">              0 :     } catch( test_being_aborted const&amp; ) {</span>
<span class="lineNum">     217 </span><span class="lineNoCov">              0 :         V.test_suite_finish( suite );</span>
<span class="lineNum">     218 </span><span class="lineNoCov">              0 :         framework::test_unit_aborted( suite );</span>
<span class="lineNum">     219 </span>                : 
<span class="lineNum">     220 </span><span class="lineNoCov">              0 :         throw;</span>
<span class="lineNum">     221 </span>                :     }
<span class="lineNum">     222 </span>                : 
<span class="lineNum">     223 </span><span class="lineCov">             12 :     V.test_suite_finish( suite );</span>
<span class="lineNum">     224 </span>                : }
<span class="lineNum">     225 </span>                : 
<span class="lineNum">     226 </span>                : //____________________________________________________________________________//
<span class="lineNum">     227 </span>                : 
<span class="lineNum">     228 </span>                : void
<span class="lineNum">     229 </span><span class="lineCov">             31 : traverse_test_tree( test_unit_id id, test_tree_visitor&amp; V )</span>
<span class="lineNum">     230 </span>                : {
<span class="lineNum">     231 </span><span class="lineCov">             31 :     if( test_id_2_unit_type( id ) == tut_case )</span>
<span class="lineNum">     232 </span><span class="lineCov">             21 :         traverse_test_tree( framework::get&lt;test_case&gt;( id ), V );</span>
<span class="lineNum">     233 </span>                :     else
<span class="lineNum">     234 </span><span class="lineCov">             10 :         traverse_test_tree( framework::get&lt;test_suite&gt;( id ), V );</span>
<span class="lineNum">     235 </span><span class="lineCov">             31 : }</span>
<span class="lineNum">     236 </span>                : 
<span class="lineNum">     237 </span>                : //____________________________________________________________________________//
<span class="lineNum">     238 </span>                : 
<span class="lineNum">     239 </span>                : // ************************************************************************** //
<span class="lineNum">     240 </span>                : // **************                test_case_counter             ************** //
<span class="lineNum">     241 </span>                : // ************************************************************************** //
<span class="lineNum">     242 </span>                : 
<span class="lineNum">     243 </span>                : void
<span class="lineNum">     244 </span><span class="lineCov">              7 : test_case_counter::visit( test_case const&amp; tc )</span>
<span class="lineNum">     245 </span>                : {
<span class="lineNum">     246 </span><span class="lineCov">              7 :     if( tc.p_enabled )</span>
<span class="lineNum">     247 </span><span class="lineCov">              7 :         ++p_count.value;</span>
<span class="lineNum">     248 </span><span class="lineCov">              7 : }</span>
<span class="lineNum">     249 </span>                : 
<span class="lineNum">     250 </span>                : //____________________________________________________________________________//
<span class="lineNum">     251 </span>                : 
<span class="lineNum">     252 </span>                : // ************************************************************************** //
<span class="lineNum">     253 </span>                : // **************               object generators              ************** //
<span class="lineNum">     254 </span>                : // ************************************************************************** //
<span class="lineNum">     255 </span>                : 
<span class="lineNum">     256 </span>                : namespace ut_detail {
<span class="lineNum">     257 </span>                : 
<span class="lineNum">     258 </span>                : std::string
<span class="lineNum">     259 </span><span class="lineCov">              7 : normalize_test_case_name( const_string name )</span>
<span class="lineNum">     260 </span>                : {
<span class="lineNum">     261 </span>                :     return ( name[0] == '&amp;'
<span class="lineNum">     262 </span>                :                 ? std::string( name.begin()+1, name.size()-1 )
<span class="lineNum">     263 </span><span class="lineCov">              7 :                 : std::string( name.begin(), name.size() ) );</span>
<span class="lineNum">     264 </span>                : }
<span class="lineNum">     265 </span>                : 
<span class="lineNum">     266 </span>                : //____________________________________________________________________________//
<span class="lineNum">     267 </span>                : 
<span class="lineNum">     268 </span>                : // ************************************************************************** //
<span class="lineNum">     269 </span>                : // **************           auto_test_unit_registrar           ************** //
<span class="lineNum">     270 </span>                : // ************************************************************************** //
<span class="lineNum">     271 </span>                : 
<span class="lineNum">     272 </span><span class="lineCov">              7 : auto_test_unit_registrar::auto_test_unit_registrar( test_case* tc, counter_t exp_fail )</span>
<span class="lineNum">     273 </span>                : {
<span class="lineNum">     274 </span><span class="lineCov">              7 :     curr_ts_store().back()-&gt;add( tc, exp_fail );</span>
<span class="lineNum">     275 </span><span class="lineCov">              7 : }</span>
<span class="lineNum">     276 </span>                : 
<span class="lineNum">     277 </span>                : //____________________________________________________________________________//
<span class="lineNum">     278 </span>                : 
<span class="lineNum">     279 </span><span class="lineCov">              2 : auto_test_unit_registrar::auto_test_unit_registrar( const_string ts_name )</span>
<span class="lineNum">     280 </span>                : {
<span class="lineNum">     281 </span><span class="lineCov">              2 :     test_unit_id id = curr_ts_store().back()-&gt;get( ts_name );</span>
<span class="lineNum">     282 </span>                : 
<span class="lineNum">     283 </span>                :     test_suite* ts;
<span class="lineNum">     284 </span>                : 
<span class="lineNum">     285 </span><span class="lineCov">              2 :     if( id != INV_TEST_UNIT_ID ) {</span>
<span class="lineNum">     286 </span><span class="lineNoCov">              0 :         ts = &amp;framework::get&lt;test_suite&gt;( id ); // !! test for invalid tu type</span>
<span class="lineNum">     287 </span><span class="lineNoCov">              0 :         BOOST_ASSERT( ts-&gt;p_parent_id == curr_ts_store().back()-&gt;p_id );</span>
<span class="lineNum">     288 </span>                :     }
<span class="lineNum">     289 </span>                :     else {
<span class="lineNum">     290 </span><span class="lineCov">              2 :         ts = new test_suite( ts_name );</span>
<span class="lineNum">     291 </span><span class="lineCov">              4 :         curr_ts_store().back()-&gt;add( ts );</span>
<span class="lineNum">     292 </span>                :     }
<span class="lineNum">     293 </span>                : 
<span class="lineNum">     294 </span><span class="lineCov">              2 :     curr_ts_store().push_back( ts );</span>
<span class="lineNum">     295 </span><span class="lineCov">              2 : }</span>
<span class="lineNum">     296 </span>                : 
<span class="lineNum">     297 </span>                : //____________________________________________________________________________//
<span class="lineNum">     298 </span>                : 
<span class="lineNum">     299 </span><span class="lineNoCov">              0 : auto_test_unit_registrar::auto_test_unit_registrar( test_unit_generator const&amp; tc_gen )</span>
<span class="lineNum">     300 </span>                : {
<span class="lineNum">     301 </span><span class="lineNoCov">              0 :     curr_ts_store().back()-&gt;add( tc_gen );</span>
<span class="lineNum">     302 </span><span class="lineNoCov">              0 : }</span>
<span class="lineNum">     303 </span>                : 
<span class="lineNum">     304 </span>                : //____________________________________________________________________________//
<span class="lineNum">     305 </span>                : 
<span class="lineNum">     306 </span><span class="lineCov">              2 : auto_test_unit_registrar::auto_test_unit_registrar( int )</span>
<span class="lineNum">     307 </span>                : {
<span class="lineNum">     308 </span><span class="lineCov">              2 :     if( curr_ts_store().size() == 0 )</span>
<span class="lineNum">     309 </span><span class="lineNoCov">              0 :         return; // report error?</span>
<span class="lineNum">     310 </span>                : 
<span class="lineNum">     311 </span><span class="lineCov">              2 :     curr_ts_store().pop_back();</span>
<span class="lineNum">     312 </span>                : }
<span class="lineNum">     313 </span>                : 
<span class="lineNum">     314 </span>                : //____________________________________________________________________________//
<span class="lineNum">     315 </span>                : 
<span class="lineNum">     316 </span>                : std::list&lt;test_suite*&gt;&amp;
<span class="lineNum">     317 </span><span class="lineCov">             17 : auto_test_unit_registrar::curr_ts_store()</span>
<span class="lineNum">     318 </span>                : {
<span class="lineNum">     319 </span><span class="lineCov">             17 :     static std::list&lt;test_suite*&gt; inst( 1, &amp;framework::master_test_suite() );</span>
<span class="lineNum">     320 </span><span class="lineCov">             17 :     return inst;</span>
<span class="lineNum">     321 </span>                : }
<span class="lineNum">     322 </span>                : 
<span class="lineNum">     323 </span>                : //____________________________________________________________________________//
<span class="lineNum">     324 </span>                : 
<span class="lineNum">     325 </span>                : } // namespace ut_detail
<span class="lineNum">     326 </span>                : 
<span class="lineNum">     327 </span>                : // ************************************************************************** //
<span class="lineNum">     328 </span>                : // **************                global_fixture                ************** //
<span class="lineNum">     329 </span>                : // ************************************************************************** //
<span class="lineNum">     330 </span>                : 
<span class="lineNum">     331 </span><span class="lineNoCov">              0 : global_fixture::global_fixture()</span>
<span class="lineNum">     332 </span>                : {
<span class="lineNum">     333 </span><span class="lineNoCov">              0 :     framework::register_observer( *this );</span>
<span class="lineNum">     334 </span><span class="lineNoCov">              0 : } </span>
<span class="lineNum">     335 </span>                : 
<span class="lineNum">     336 </span>                : //____________________________________________________________________________//
<span class="lineNum">     337 </span>                : 
<span class="lineNum">     338 </span>                : } // namespace unit_test
<span class="lineNum">     339 </span>                : 
<span class="lineNum">     340 </span>                : } // namespace boost
<span class="lineNum">     341 </span>                : 
<span class="lineNum">     342 </span>                : //____________________________________________________________________________//
<span class="lineNum">     343 </span>                : 
<span class="lineNum">     344 </span>                : #include &lt;boost/test/detail/enable_warnings.hpp&gt;
<span class="lineNum">     345 </span>                : 
<span class="lineNum">     346 </span>                : #endif // BOOST_TEST_UNIT_TEST_SUITE_IPP_012205GER
</pre>
      </td>
    </tr>
  </table>
  <br>

  <table width="100%" border=0 cellspacing=0 cellpadding=0>
  <tr><td class="ruler"><img src="../../glass.png" width=3 height=3 alt=""></td></tr>
  <tr><td class="versionInfo">Generated by: <a href="http://ltp.sourceforge.net/coverage/lcov.php" target="_parent">LTP GCOV extension version 1.6</a></td></tr>
  </table>
  <br>

</body>
</html>
